<%@ include file="/html/portlet/ext/especialidade/init.jsp" %>

<%
String redirect = ParamUtil.getString(request, "redirect");

Etapa etapa = (Etapa)request.getAttribute("ETAPA");

String etapaId = BeanParamUtil.getString(etapa, request, "etapa_id");

String className = BeanParamUtil.getString(etapa, request, "className");
String classPK = BeanParamUtil.getString(etapa, request, "classPK");

String item = BeanParamUtil.getString(etapa, request, "item");
String descricao = BeanParamUtil.getString(etapa, request, "descricao");
%>

<script type="text/javascript">
	function <portlet:namespace />saveEtapa() {
		document.<portlet:namespace />fm.<portlet:namespace /><%= Constants.CMD %>.value = "<%= idioma == null ? Constants.ADD : Constants.UPDATE %>";
		submitForm(document.<portlet:namespace />fm);
	}
</script>
<form action="<portlet:actionURL windowState="<%= WindowState.MAXIMIZED.toString() %>"><portlet:param name="struts_action" value="/ext/especialidade/edit_etapa" /></portlet:actionURL>" method="post" name="<portlet:namespace />fm" onSubmit="<portlet:namespace />saveEtapa(); return false;">
<input name="<portlet:namespace /><%= Constants.CMD %>" type="hidden" value="">
<input name="<portlet:namespace />redirect" type="hidden" value="<%= redirect %>">
<input name="<portlet:namespace />etapa_id" type="hidden" value="<%= etapaId %>">
<input name="<portlet:namespace />className" type="hidden" value="<%= className %>">
<input name="<portlet:namespace />classPK" type="hidden" value="<%= classPK %>">

<liferay-ui:tabs names="Etapa" />


<table border="0" cellpadding="0" cellspacing="0">
<tr>	
	<td>
		Etapa
	</td>
	<td style="padding-left: 10px;"></td>
	<td>
		<td>
			<input name="<portlet:namespace />item" type="text" size="3" maxlength="2" value="<%= item %>">
		</td>
		<td>
			<input name="<portlet:namespace />descricao" type="text" size="25" maxlength="80" value="<%= descricao %>">
		</td>
	</td>
<tr>	
</table>

<br>

<input class="portlet-form-button" type="submit" value='<%= LanguageUtil.get(pageContext, "save") %>'>

<input class="portlet-form-button" type="button" value='<%= LanguageUtil.get(pageContext, "cancel") %>' onClick="self.location = '<%= redirect %>';">

</form>
</body>
<script type="text/javascript">
	document.<portlet:namespace />fm.<portlet:namespace />descricao.focus();
</script>
